package com.example.demo.service;

import com.example.demo.exception.ServiceException;
import com.example.demo.param.vo.CollectionVO;

public interface ICollectionService {
    /**
     * 新增收藏
     * @param userId
     * @param questionId
     * @return
     * @throws ServiceException
     */
    Boolean insert(String userId, String questionId) throws ServiceException;

    /**
     * 取消收藏
     * @param id
     * @return
     * @throws ServiceException
     */
    Boolean delete(String id)throws ServiceException;

    /**
     * 查询我的所有收藏
     * @param userId
     * @param page
     * @param pageSize
     * @return
     */
    CollectionVO getMyCollection(String userId, Integer page, Integer pageSize);
}
